<script setup lang="ts">
// This starter template is using Vue 3 <script setup> SFCs
// Check out https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup
// import HelloWorld from './components/HelloWorld.vue'
import { ref,computed} from '@vue/reactivity';
import { onMounted } from '@vue/runtime-core';
import { useStore } from './store';
const props = defineProps({
  title: {
    type: String,
    default: () => { return "标题" }
  }
})
const store = useStore();

const msg = ref("父组件的值");

let num = ref(1);

const handleChange = (str: string) => {
  // console.log(str);
  num.value++;
  msg.value = str + num.value;
}
// const csRef = ref();
onMounted(() => {
  // console.log(csRef.value);
  // csRef.value.hide();
  // setTimeout(() => {
  //   csRef.value.show();
  // }, 2000);
})
</script>

<template>
  <router-view></router-view> 
  <!-- <cs ref="csRef" :class-name="msg" @on-change="handleChange"></cs> -->
</template>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  height: 100%;
  /* margin-top: 60px; */
}
</style>
